<template>
  <view class="my-box">
    <!-- 登录组件 -->
    <my-login v-if="!token"></my-login>
    <!-- 个人信息组件 -->
    <my-userinfo v-else></my-userinfo>
  </view>
</template>

<script>
import tabBarBadge from '@/mixins/tabBar-badge.js';
import myLogin from '../../components/my-login/my-login.vue'
import myUserinfo from '../../components/my-userinfo/my-userinfo.vue'
import {mapState} from 'vuex'
export default {
  mixins: [tabBarBadge],
  data() {
    return {};
  },
  computed:{
    ...mapState('myAddress',['token'])
  },
  components:{
    'my-login':myLogin,
    'my-userinfo':myUserinfo
  },
  
  
};
</script>

<style lang="scss">
  page,.my-box {
    height: 100%;
  }
</style>
